package sar

class ProgramCourse {
	static belongsTo=[program:Program,course:Course]
	Date startDate
	Date endDate
	static constraints = {
		startDate blank:false, nullable:false
		endDate blank:false, nullable:false
	}
	static mappedBy=[
		program:'program_id',course:'course_id'
	]
	@Override
	public String toString() {
		return program.name+"-"+course.name+"-"+startDate.format("dd:MM:yyyy")
	}
}
